﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace _Sql查询结果转List
{
    class Program
    {
        static void Main(string[] args)
        {
            string connStr = System.Configuration.ConfigurationManager.ConnectionStrings["Default"].ToString();
            List<Sutdent> sutdents = SqlHelper.GetList<Sutdent>(connStr,System.Data.CommandType.Text,"Select * from Student where Sex='男'");

            StudentDAL dal = new StudentDAL();
            List<Sutdent> sutdentsByDAL = dal.GetAllList(connStr, System.Data.CommandType.Text, "Select * from Student where Sex='男'");

        }
    }
}
